﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.ServiceModel;
using System.ServiceModel.Web;

namespace TipokHostContract
{
    /// <summary>
    /// 提供给通讯服务层的接口定义
    /// </summary>
    [ServiceContract]
    public interface IContractServiceStrategy
    {
        [OperationContract]
        [FaultContract(typeof(ErrorInfo))]
        List<ServiceModel> GetServices();

        [OperationContract]
        [FaultContract(typeof(ErrorInfo))]
        ServiceModel GetService(int id, int servicetype);

        [OperationContract]
        [FaultContract(typeof(ErrorInfo))]
        void InstallService(int id, int servicetype, string password);

        [OperationContract]
        [FaultContract(typeof(ErrorInfo))]
        void KillProcessForcibly(int id, int servicetype);

        [OperationContract]
        [FaultContract(typeof(ErrorInfo))]
        void RestartService(int id, int servicetype);

        [OperationContract]
        [FaultContract(typeof(ErrorInfo))]
        void StartService(int id, int servicetype);

        [OperationContract]
        [FaultContract(typeof(ErrorInfo))]
        void StopService(int id, int servicetype);

        [OperationContract]
        [FaultContract(typeof(ErrorInfo))]
        void UnInstallService(int id, int servicetype);

        [OperationContract]
        [FaultContract(typeof(ErrorInfo))]
        void UpService(int id, int servicetype, string password);
    }
}
